<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <meta http-equiv="X-UA-Compatible" content="ie=edge" />
    <title>javascript</title>
    <style>
      * {
        margin: 0;
        padding: 0;
        box-sizing: border-box;
      }
      body {
        font-size: 14px;
      }
      ul li {
        line-height: 30px;
      }
      .bfc {
        overflow: hidden;
        font-size: 0px;
      }
      .box1 {
        width: 200px;
        height: 200px;
        background: red;
        display: inline-block;
      }
      .box2 {
        width: 300px;
        height: 300px;
        background: blue;
        display: inline-block;
      }
      div#test span {
        color: green;
      }
      span {
        color: red;
      }
      div span {
        color: blue;
      }
      .bg {
        background: red;
      }
    </style>
  </head>
  <body>
    <div class="bfc">
      <div
        style="
          width: 100px;
          height: 100px;
          background: red;
          margin-bottom: 20px;
        "
      ></div>
      <div class="bfc">
        <div
          style="
            width: 100px;
            height: 100px;
            background: blue;
            margin-top: 20px;
          "
        ></div>
      </div>
    </div>
    <div style="height: auto; background: red; overflow: hidden">
      <div style="float: left">kfjdsjfsjfl</div>
    </div>
    <div style="background: green; width: 300px">
      <div
        style="width: 100px; height: 100px; background: blue; float: left"
      ></div>
      <div class="bfc">
        <div>
          我是元素哈哈哈我是元素哈哈哈我是元素哈哈哈我是元素哈哈哈我是元素哈哈哈我是元素哈哈哈我是元素哈哈哈我是元素哈哈哈我是元素哈哈哈我是元素哈哈哈我是元素哈哈哈我是元素哈哈哈我是元素哈哈哈我是元素哈哈哈
        </div>
      </div>
    </div>
    <ul id="ulD">
      <li>
        <div>111</div>
        <div>11111</div>
      </li>
      <li>
        <div>111</div>
        <div>22222</div>
      </li>
    </ul>
  </body>

  <script src="https://cdn.bootcss.com/vue/2.6.8/vue.js"></script>
  <script>
    var obj = {
      foo: "bar",
      show: function () {
        var self = this;
        console.log(this.foo);
        console.log(self.foo);
        (function () {
          console.log(this.foo);
          console.log(self.foo);
        })();
      },
    };
    obj.show();
    window.localStorage.setItem("loginTag", "zhangli");
    window.sessionStorage.setItem("quitTag", "haha");
  </script>
</html>
